package com.lhkj.ct.base.enums;

import com.baomidou.mybatisplus.annotation.EnumValue;
import com.baomidou.mybatisplus.annotation.IEnum;

/**
 * <p>
 *     全局状态枚举
 * </p>
 */
public enum GlobalStatus implements IEnum<Integer> {

    NORMAL(0, "启用"),
    DISABLED(1, "禁用");

    @EnumValue
    private final int code;

    private final String desc;

    GlobalStatus(int code, String desc) {
        this.code = code;
        this.desc = desc;
    }

    @Override
    public String toString() {
        return String.valueOf(code);
    }

    @Override
    public Integer getValue() {
        return code;
    }

    public String getDesc() {
        return desc;
    }

}
